package win.demonlegion.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import win.demonlegion.mapper.SysRoleAuthorityMapper;
import win.demonlegion.module.SysAuthorityBean;
import win.demonlegion.module.SysRoleAuthorityBean;
import win.demonlegion.service.inte.SysRoleAuthorityService;

import java.util.List;

@Service("sysRoleAuthorityService")
public class SysRoleAuthorityServiceImpl implements SysRoleAuthorityService {
    @Autowired
    private SysRoleAuthorityMapper sysRoleAuthorityMapper;

    @Override
    public int add(SysRoleAuthorityBean sysRoleAuthorityBean) {
        return sysRoleAuthorityMapper.add(sysRoleAuthorityBean);
    }

    @Override
    public List<SysAuthorityBean> getUserAuthority(String userId) {
        return sysRoleAuthorityMapper.getUserAuthority(userId);
    }
}
